using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using yq.IBase;
using yq.Model.Base;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;
using cn.Util;

namespace yq.Model.Logic
{
    /// <summary>
    /// Article_Comment - 评论表 - 对象继承类
    /// </summary>
    [MetadataType(typeof(ArticleCommentValidaTion))]
    public class ArticleComment : IArticleComment<ArticleComment>
    {


       #region 生成实体类验证属性
       /// <summary>
       /// 辅助验证类
       /// </summary>
       [Bind]
       public class ArticleCommentValidaTion
       {

     

        /// <summary>
        /// 评论id
        /// </summary>
        [Display(Name ="评论id")]
        [Required]
        [StringLength(36)]
        public String CommentId
        {
         get; set; 
        }


       
     

        /// <summary>
        /// UserId
        /// </summary>
        [Display(Name ="UserId")]
        [Required]
        [StringLength(36)]
        public String UserId
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 关联表ID
        /// </summary>
        [Display(Name ="关联表ID")]
        [Required]
        [StringLength(36)]
        public String ModelsId
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 状态
        /// </summary>
        [Display(Name ="状态")]
        [Required]
       [RegularExpression(RegularExpressionString.Int, ErrorMessage="必须输入数字")]

        public yq.Enums.ArticleComment.State State
        {
         get; set; 
        }


       
     

        /// <summary>
        /// IP
        /// </summary>
        [Display(Name ="IP")]
        [StringLength(50)]
        public String Ip
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 赞同数
        /// </summary>
        [Display(Name ="赞同数")]
       [RegularExpression(RegularExpressionString.Int, ErrorMessage="必须输入数字")]

        public int AgreeCount
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 评论内容
        /// </summary>
        [Display(Name ="评论内容")]
        [Required]
        [StringLength(700)]
        public String ConText
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 评论时间
        /// </summary>
        [Display(Name ="评论时间")]
        [Required]

        public DateTime SubmitTime
        {
         get; set; 
        }


       
     

        /// <summary>
        /// 修改时间
        /// </summary>
        [Display(Name ="修改时间")]

        public DateTime EditTime
        {
         get; set; 
        }


       

       
       }
       #endregion 生成实体类验证属性
    }
}
